#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
#include<string.h>
void print(char* str)
{
	char* left = str;
	char* right = str + strlen(str) - 1;
	while (left < right)
	{
		char tmp = *left;
		*left = *right;
		*right = tmp;
		right--;
		left++;
	}
}
int main()
{
	char str[10000] = { 0 };
	while (gets(str) != EOF)
	{
		print(str);
		printf("%s\n", str);
		return 0;
	}
}